<!DOCTYPE html>

{% load static %}
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>MyWebsite | Registration Page</title>

  <!-- Google Font: Source Sans Pro -->
  <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">
  <!-- Font Awesome -->
  <link href=" {% static 'plugins/fontawesome-free/css/all.min.css' %}" rel="stylesheet">
  <!-- icheck bootstrap -->
  <link href=" {% static 'plugins/icheck-bootstrap/icheck-bootstrap.min.css' %}" rel="stylesheet">
  <!-- Theme style -->
  <link href=" {% static 'dist/css/adminlte.min.css' %}" rel="stylesheet">
</head>
<body class="hold-transition register-page">
<div class="register-box">
  <div class="register-logo">
    <a href=""><b>Web</b>Authentication</a>
  </div>

  <div class="card">
    <div class="card-body register-card-body">
      <p class="login-box-msg">Register a new membership</p>
      <form action="/register/" method="post">
        {% if message %}
        <div class="alert alert-warning">{{ message }}</div>
        {% endif %}
        {% csrf_token %}
        <div class="input-group mb-3">
          {{ register_form.username}}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-user"></span>
            </div>
          </div>
        </div>
        <div class="input-group mb-3">
          {{ register_form.email }}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-envelope"></span>
            </div>
          </div>
        </div>
        <div class="input-group mb-3">
          {{ register_form.password1 }}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-lock"></span>
            </div>
          </div>
        </div>
        <div class="input-group mb-3">
          {{ register_form.password2 }}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-lock"></span>
            </div>
          </div>
        </div>
        <div class="input-group mb-3">
              {{ register_form.sex }}
        </div>

        <div class="input-group mb-3">
          {{ register_form.captcha.errors }}
          {{ register_form.captcha }}
        </div>
        <div class="row">
          <div class="col-8">
            <div class="icheck-primary">
              <input type="checkbox" id="agreeTerms" name="terms" value="agree">
              <label for="agreeTerms">
               I agree to the <a href="#">terms</a>
              </label>
            </div>
          </div>
          <!-- /.col -->
          <div class="col-4">
            <button type="submit" class="btn btn-primary btn-block">Register</button>
          </div>
          <!-- /.col -->
        </div>
      </form>

      <a href="/login" class="text-center">I already have a membership</a>
    </div>
    <!-- /.form-box -->
  </div><!-- /.card -->
</div>
<!-- /.register-box -->

<!-- jQuery -->
<script src=" {% static 'plugins/jquery/jquery.min.js' %}"></script>
<!-- Bootstrap 4 -->
<script src=" {% static 'plugins/bootstrap/js/bootstrap.bundle.min.js' %}"></script>

<!-- AdminLTE App -->
<script src=" {% static 'dist/js/adminlte.min.js' %}"></script>
</body>
</html>
